<template>
  <div>
    <van-nav-bar
      title="我的收藏"
      left-text="返回"
      left-arrow
      @click-left="onClickLeft"
    >
      <template #right>
        <van-image
          round
          width="1rem"
          height="1rem"
          fit="contain"
          :src="this.userInfo.photo"
        />
      </template>
    </van-nav-bar>

    <div class="container">
      <h1>{{ this.info }}</h1>
      <ul>
        <li v-for="(value, index) of myCollects" :key="index">
          <p><span>时间：</span> {{ value.nowTime }}</p>
          <h1><span> 地点：</span>{{ value.title }}</h1>
          <img :src="value.imgsrc" alt="" />
        </li>
      </ul>
    </div>
  </div>
</template>
<script>
export default {
  data() {
    return {
      info: "",
      userInfo: JSON.parse(localStorage.getItem("userInfo")),
      myCollects: JSON.parse(localStorage.getItem("myCollects")),
    };
  },
  created() {
   
  },
  computed: {},
  methods: {
    onClickLeft() {
      /* console.log(1); */
      this.$router.go(-1);
    },
  },
};
</script>
<style lang="scss" scoped>
.container{
  width: 96%;
  margin-left: 2%;
  
}
li{
  margin-top: 0.5rem;
}
span{
  font-size: 20px;
}
p{
  font-size: 16px;
}
h1{
  font-size: 16px;
  margin-top: 0.1rem;
  margin-bottom: 0.1rem;
}
</style>
